package com.filetransfer.model.common;

import lombok.Getter;

/**
 * 业务逻辑异常
 */
@Getter
public class BusinessException extends RuntimeException {

    private final int code;
    
    private final String message;
    
    public BusinessException(String message) {
        this(500, message);
    }
    
    public BusinessException(int code, String message) {
        super(message);
        this.code = code;
        this.message = message;
    }
    
    public Integer getCode() {
        return code;
    }
    
    @Override
    public String getMessage() {
        return message;
    }
} 